<!-- Vue SFC -->
<template>
  <div>
    <Treeselect v-model="value" :options="options" :multiple="true" />
    {{ value }}===>
  </div>
</template>

<script>
export default {
  data() {
    return {
      value: null,
      options: [
        {
          id: 1,
          label: '一级选项1',
          children: [
            {
              id: 11,
              label: '二级选项1-1',
              children: [
                {
                  id: 111,
                  label: '三级选项1-1-1',
                },
                {
                  id: 112,
                  label: '三级选项1-1-2',
                },
              ],
            },
            {
              id: 12,
              label: '二级选项1-2',
              children: [
                {
                  id: 121,
                  label: '三级选项1-2-1',
                },
                {
                  id: 122,
                  label: '三级选项1-2-2',
                },
              ],
            },
          ],
        },
        {
          id: 2,
          label: '一级选项2',
          children: [
            {
              id: 21,
              label: '二级选项2-1',
              children: [
                {
                  id: 211,
                  label: '三级选项2-1-1',
                },
                {
                  id: 212,
                  label: '三级选项2-1-2',
                },
              ],
            },
            {
              id: 22,
              label: '二级选项2-2',
              children: [
                {
                  id: 221,
                  label: '三级选项2-2-1',
                },
                {
                  id: 222,
                  label: '三级选项2-2-2',
                },
              ],
            },
          ],
        },
      ],
    };
  },
};
</script>
